<script setup lang="ts">
import { ref } from "vue";

interface PropType {
  isDoc?: boolean; // 是否为文档系统
}

withDefaults(defineProps<PropType>(), {
  isDoc: false,
});

const searchForm = ref({
  page: 2,
  size: 10,
  total: 1000,
});

const change = (page, size) => {
  console.log(searchForm.value);
  console.log(page, size);
};
</script>

<template>
  <div class="page-container w-full h-full">
    <xt-row>
      <xt-col :span="24">
        <xt-card class="card-container" header="基础">
          <xt-pagination
            v-model:current-page="searchForm.page"
            v-model:page-size="searchForm.size"
            :total="searchForm.total"
            @change="change"
          />
        </xt-card>
      </xt-col>
    </xt-row>
  </div>
</template>

<style lang="scss">
.page-container {
  .card-container {
    @apply m-[10px];
  }
}
</style>
